/**
 * @Title: SercurityService.java 
 * @Description: TODO
 * @author <a href="mailto:psammead@126.com">Psammead</a>
 * @date 2011-7-15 下午10:12:01 
 * @version 1.0
 * Copyright 2011 by Psammead
 */
package com.psammead.dms.system.sercurity.service;

import java.util.List;

import com.psammead.dms.system.sercurity.entity.SysPermission;

/**
 * @ClassName: SercurityService
 * @Description: 系统安全业务逻辑接口
 * @author <a href="mailto:psammead@126.com">psammead</a>
 * @version 1.0
 * @date 2011-7-15
 */
public interface SercurityService {
	
	/**
	 * 校验用户登录信息是否合法
	 * @Title: validUserLogin
	 * @Description: TODO
	 * @param loginName
	 * @param password
	 * @return 
	 * @return boolean
	 * @throws
	 */
	public boolean validUserLogin(String loginName, String password);
	
	/**
	 * 获取用户的权限列表
	 * @Title: getUserPermission
	 * @Description: TODO
	 * @param userId
	 * @return 
	 * @return List<SysPermission>
	 * @throws
	 */
	public List<SysPermission> getUserPermission(long userId);
	
	/**
	 * 判断用户是否具有对某个资源的某种操作权限
	 * @Title: hasUserPermission
	 * @Description: TODO
	 * @param user
	 * @param resourceId
	 * @param operationId
	 * @return 
	 * @return boolean
	 * @throws
	 */
	public boolean hasUserPermission(long user, long resourceId, long operationId);
}
